package stack;

public class Test {
public static void main(String[] args) {
	STackand stack=new STackand();
	stack.push("1");
	stack.push("2");
	stack.push("3");
	stack.push("4");
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());	
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());

    System.out.println("size"+stack.size());
    stack.push("1");
	stack.push("2");
	stack.push("3");
	stack.push("4");
	 
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());	
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());

	stack.clear();
	stack.push("1");
	stack.push("2");
	stack.push("3");
	stack.push("4");
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());	
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());
	
	System.out.println(stack.peek());
	System.out.println(stack.pop());


	
}
}
